package onlineslideshow.test;

import com.zehon.exception.FileTransferException;
import java.io.File;
import javax.swing.JOptionPane;
import onlineslideshow.ftp.ftpTransaction;

/**
 *
 * @author alex.nebel
 */
public class testFtpTransaction {

    public static void main(String[] args) {
        ftpTransaction ftpt = new ftpTransaction();
        boolean connected = ftpt.connect("192.168.0.56", 21, "meins", JOptionPane.showInputDialog(null, "test"));
        ftpt.setFolder(false);
//        ftpt.setLocalFolder("C:\\Users\\meins\\Pictures");
        ftpt.addFile(new File("C:\\Users\\meins\\Pictures\\murderturtle.gif"));
        ftpt.setRemoteFolder("testfolder\\pictures");
        try {
            ftpt.start();
            System.out.println("finished");
        } catch (FileTransferException ex) {
            ex.printStackTrace();
        }
    }
}
